<?php
	defined( "AZ_EXE_" ) or die ( "ERROR : CORE VARIABLE IS NOT DEFINED." );
	$http = @$_SERVER["HTTPS"] == "on"? "https://": "http://";
	define ('BASE_URL', $http . $_SERVER['HTTP_HOST'] . (rtrim($_SERVER['SCRIPT_NAME'],basename($_SERVER['PHP_SELF']))));
	define( "DS" , DIRECTORY_SEPARATOR );
	define( "ROOT_FOLDER" , dirname ( dirname( dirname ( __FILE__ ) ) ) . DS );
	/* Define Main Folder Of FSI */
	define( "APP_FOLDER" , ROOT_FOLDER . "app" . DS );
	define( "LIBRARY_FOLDER" , ROOT_FOLDER . "az" . DS );
	define( "WEB_FOLDER" , ROOT_FOLDER . "web" . DS );
	define( "VENDOR_FOLDER" , ROOT_FOLDER . "vendor" . DS );
	/* Define Core Folder Of Application */
	define( "APP_LIBS_FOLDER" , APP_FOLDER . "libs" . DS );
	define( "APP_LOCALE_FOLDER" , APP_FOLDER . "locale" . DS );
	define( "CONTROLLER_FOLDER" , APP_FOLDER . "controllers" . DS );
	define( "MODEL_FOLDER" , APP_FOLDER . "models" . DS );
	define( "VIEW_FOLDER" , APP_FOLDER . "views" . DS );
	/* Define Core Folder Of Library */
	define( "CORE_FOLDER" , LIBRARY_FOLDER . "core" . DS );
	define( "DATASOURCE_FOLDER" , CORE_FOLDER . "datasource" . DS );
	define( "UTIL_FOLDER" , CORE_FOLDER . "util" . DS );
	define( "CORE_APP_FOLDER" , CORE_FOLDER . "app" . DS );
	define( "TEMPLATE_FOLDER" , CORE_APP_FOLDER . "view" . DS );
	define( "CORE_HTML_FOLDER" , CORE_FOLDER . "html" . DS );
	define( "CORE_ELEMENT_FOLDER" , TEMPLATE_FOLDER . "elements" . DS );
	define( "CORE_LAYOUT_FOLDER" , TEMPLATE_FOLDER . "layouts" . DS );
	/* Define Core Folder Of Web Folder */
	define( "CSS_FOLDER" ,  "web/public/css/" );
	define( "IMG_FOLDER" , "web/public/img/" );
	define( "JS_FOLDER" , "web/public/js/" );
	define( "ADMIN_SITE_NAME", "::: SMECA CLINIC");
	require_once( CORE_FOLDER . "AZ.php" );
	require_once( UTIL_FOLDER . "Session.php" );
	SESSION::start();
	require_once( UTIL_FOLDER . "Basic.php" );
	require_once( UTIL_FOLDER . "Import.php" );
	require_once( CORE_APP_FOLDER . "Model.php" );
	require_once( CORE_FOLDER . "Router.php");
	require_once( CORE_APP_FOLDER . "View.php" );
	require_once( CORE_APP_FOLDER . "Controller.php" );
	require_once( CORE_FOLDER . "html".DS."HTML.php");
	require_once( UTIL_FOLDER . "Cookie.php" );
	require_once( APP_FOLDER . "config" . DS . "database.php" );
	$route = new Router();
	require_once( APP_FOLDER . "config" . DS . "route.php" );
	
?>